﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Text;
using Abp.Application.Services.Dto;
using Abp.AutoMapper;
using Abp.Domain.Entities;
using Abp.Domain.Entities.Auditing;
using AutoMapper;
using FwProject.Authorization.Users;
using FwProject.Core.Restaurant;
using Newtonsoft.Json;

namespace FwProject.Restaurant.Dto
{
    /// <summary>
    /// 餐厅分布
    /// </summary>
    [AutoMapFrom(typeof(RestaurantInfo))]
    public class RestaurantDistributedDto : EntityDto<Guid>
    {
        /// <summary>
        /// 餐厅地址
        /// </summary>
        /// <value>The restaurant address.</value>
        [Display(Name = "餐厅地址")]
        public string RestaurantAddress { get; set; }


        /// <summary>
        /// 餐厅名称
        /// </summary>
        /// <value>The name of the restaurant.</value>

        [Display(Name = "餐厅名称")]
        public string RestaurantName { get; set; }


        /// <summary>
        /// 经度
        /// </summary>
        /// <value>The longitude.</value>

        [Display(Name = "经度")]
        public string longitude { get; set; }


        /// <summary>
        /// 纬度
        /// </summary>
        /// <value>The latitude.</value>

        [Display(Name = "纬度")]
        public string latitude { get; set; }
        
        /// <summary>
        /// 餐厅logo 图片
        /// </summary>
        /// <value>The thump.</value>
        [Display(Name = "餐厅logo图片")]
        public string Thump { get; set; } = RestaurantInfo.SavePath;

        /// <summary>
        /// 司机
        /// </summary>
        public RestaurantDriver EmployeeDriver { get; set; }

        [AutoMapFrom(typeof(User))]
        public class RestaurantDriver
        {
            public string Name { get; set; }
        }
    }


    public class RestaurantAdvancePaymentDto:EntityDto<Guid>
    {
        /// <summary>
        /// 餐厅名称
        /// </summary>
        /// <value>The name of the restaurant.</value>

        [Display(Name = "餐厅名称")]
        public string RestaurantName { get; set; }

        /// <summary>
        /// 预收款
        /// </summary>
        public decimal AdvancePayment { get; set; }
    }

}
